# $Id$
# Maintainer: Ray Rashif <schiv@archlinux.org>
# Contributor: damir <damir@archlinux.org>

pkgname=qsynth
pkgver=0.4.3
pkgrel=1
pkgdesc="Qt GUI for FluidSynth"
arch=('i686' 'x86_64')
url="http://qsynth.sourceforge.net/"
license=('GPL')
depends=('fluidsynth' 'qt5-x11extras' 'hicolor-icon-theme')
makedepends=('qt5-tools')
source=("http://downloads.sourceforge.net/$pkgname/$pkgname-$pkgver.tar.gz")
md5sums=('997cd7f7cd83cd6d61f9d7aba5d6c88a')

prepare() {
  cd $pkgname-$pkgver
  # Fix build with GCC 6
  #sed -i.ac_with_paths -e "s|^ac_with_paths=.*|ac_with_paths=|g" configure
}

build() {
  cd "$srcdir/$pkgname-$pkgver"

  export ac_qmake=/usr/bin/qmake-qt5 \
         ac_moc=/usr/bin/moc-qt5 \
         ac_uic=/usr/bin/uic-qt5 \
         ac_lupdate=/usr/bin/lupdate-qt5 \
         ac_lrelease=/usr/bin/lrelease-qt5 \
         QMAKE=qmake-qt5

  ./configure --prefix=/usr
  make
}

package() {
  cd "$srcdir/$pkgname-$pkgver"

  make DESTDIR="$pkgdir" install
}

# vim:set ts=2 sw=2 et:
